
<div class="span10">
          <div class="row-fluid">
            <div class="span12 box">
                <div class="box-head">
                    <h3><i class="icon-white icon-file"></i> Tambah Agenda</h3>
                </div>
                <div class="box-content">
                 <div class="content-inner">
                   <?php echo form_error('tema', '<div class="alert alert-info"><button type="button" class="close" data-dismiss="alert"><i class="icon-fullscreen"></i></button>', '</div>'); ?>
                   <?php echo form_error('isi_agenda', '<div class="alert alert-info"><button type="button" class="close" data-dismiss="alert"><i class="icon-fullscreen"></i></button>', '</div>'); ?>
                    <?php echo form_error('mulai', '<div class="alert alert-info"><button type="button" class="close" data-dismiss="alert"><i class="icon-fullscreen"></i></button>', '</div>'); ?>
                     <?php echo form_error('selesai', '<div class="alert alert-info"><button type="button" class="close" data-dismiss="alert"><i class="icon-fullscreen"></i></button>', '</div>'); ?>
                   <form class="form-horizontal" method="post" action="<?php echo base_url();?>admin/agenda/update" enctype="multipart/form-data">
                   <?php foreach($data as $r): ?>
                   <input type="hidden" name="id" value="<?php echo $r['id_agenda']; ?>">
                   <input type="hidden" name="gambar" value="<?php echo $r['gambar']; ?>" />
                           <div class="control-group">
	      						<label class="control-label">Tema Agenda</label>
                                <div class="controls">
                           				<input type="text" placeholder="Tema Agenda" name="tema" class="input-xxlarge" value="<?php echo $r['tema']; ?>"> 
                                </div>
                          </div>
                          
                          <div class="control-group">
	      						<label class="control-label">Isi Agenda</label>
                                <div class="controls">
                           			<textarea id="textarea" rows="20" class="span8" name="isi_agenda"><?php echo $r['isi_agenda']; ?></textarea>
                           		</div>
                           </div>
                           <div class="control-group">
	      						<label class="control-label"></label>
                                <div class="controls">
                                  <table class="table">
                                    <thead>
                                      <tr>
                                        <th>Tanggal Mulai: <input type="text" class="span4" id="dpd1" name="mulai" data-date-format="yyyy-mm-dd" value="<?php echo $r['tgl_mulai']; ?>" ></th>
                                        <th>Tanggal Selesai: <input type="text" class="span4" id="dpd2"  name="selesai" data-date-format="yyyy-mm-dd" value="<?php echo $r['tgl_selesai']; ?>"></th> 
                                      </tr>
                                    </thead>
                                  </table>
      							</div>
                           </div>
      
      					<div class="control-group">
	      						<label class="control-label">Tempat</label>
                                <div class="controls">
                           				<input type="text" placeholder="Tempat" name="tempat" class="input-xxlarge" value="<?php echo $r['tempat']; ?>"> 
                                </div>
                          </div>
                          
                          <div class="control-group">
	      						<label class="control-label">Foto</label>
                                <div class="controls">
                           			<!--<input name="userfile" type="file" id="gambar" size="40" /> -->
                                    <div class="fileupload fileupload-exists" data-provides="fileupload">
                                      <div class="fileupload-new thumbnail" style="width: 200px; height: 150px;"><img src="<?php echo base_url();?>image/noimage.gif" /></div>
                                      <div class="fileupload-preview fileupload-exists thumbnail" style="max-width: 200px; max-height: 150px; line-height: 20px;">
                                      <img src="<?php echo base_url();?>image/gambar_event/<?php echo $r['gambar'];?>" />
                                      </div>
                                      <div>
                                        <span class="btn btn-file"><span class="fileupload-new">Select image</span><span class="fileupload-exists">Change</span>
                                        <input name="userfile" type="file" id="file_foto" />
                                        </span>
                                        <a href="#" class="btn fileupload-exists btn-danger" data-dismiss="fileupload">Remove</a>
                                      </div>
                                    </div>
                                </div>
                           </div>    
                            
                            <div class="control-group">
	      						<label class="control-label">&nbsp;</label>
                                <div class="controls">
                           			<input type="submit" class="btn btn-primary" value="Simpan" />
                                    <input type="reset" class="btn btn-danger" value="Reset" />
                           		</div>
                           </div>
                                <!--<button type="submit" class="btn btn-primary" onClick="ste.submit();">Publish &#43;</button> -->
                         <?php endforeach; ?>
                        </form>
                </fieldset>
              </div>
            </div>
          </div> <!-- end row -->
          
        </div>
</div>
        